package com.boyi.center.controller;


import com.boyi.shared.common.Result;
import io.swagger.annotations.ApiOperation;

import java.util.List;

/**
 * @author Yan Peixuan
 * @date 2017/3/28 21:06
 * @description
 */
public interface BaseController<T> {
    //    Result<List<T>> selectByPrimaryKey(Object key);
    @ApiOperation("保存")
    Result<List<T>> save(T entity);

    @ApiOperation("删除")
    Result<List<T>> delete(T entity);

    //    Result<List<T>> updateByPrimaryKey(T entity);
    @ApiOperation("修改")
    Result<List<T>> updateNotNull(T entity);

//    List<T> selectByExample(Object example);

    //    List<T> selectByUser(Object example, int page, int rows);
    @ApiOperation("查询")
    Result<List<T>> select(T entity);
}
